package com.example.aerohub.exception;

import lombok.Getter;

@Getter
public enum ErrorCode {

	SUCCESS(200, "Successful"),
	FAILED(400, "Failed"),
	NO_PRICING_AVAILABLE(1002, "The route has no pricing available"),
	NO_QUOTES_SSR(5013, "There are no quotes available for SSR."),
	QUOTE_EXPIRED(5102, "Quote data cache has expired"),
	POLICY_NOT_FOUND(5104, "Policy not found"),
	INVALID_REQUEST(5105, "Invalid request"),
	PASSENGER_NOT_ALLOWED(5107, "Passenger not allowed"),
	NO_AVAILABLE_SEATS(5109, "No Available Seats in Requested Class"),
	NO_AVAILABLE_SEATS_ORDER(5110, "No Available Seats in Requested Class (Order)"),
	NO_AVAILABLE_SEATS_LOCK(5111, "No Available Seats in Requested Class (Lock)"),
	PROMO_CHANGED(5113, "Promo changed"),
	METADATA_NOT_FOUND(5117, "Metadata not found"),
	SYSTEM_ERROR(5118, "System error"),
	ROUTE_NOT_SUPPORTED(5119, "Route not supported"),
	ROUTE_NOT_IN_WHITELIST(5120, "Route not in whitelist"),
	ROUTE_IN_BLACKLIST(5121, "Route in blacklist"),
	NO_POLICY_FOR_ROUTE(5122, "No policy for route"),
	SEARCH_DATE_NOT_SUPPORTED(5123, "Search date not supported"),
	NO_METHOD_SUPPORTED(5124, "No method supported"),
	NO_CARRIER_SUPPORTED(5125, "No carrier supported"),
	TRIP_TYPE_NOT_SUPPORTED(5126, "Trip type not supported"),
	OVER_MAX_WAITING_TIME(5127, "Over max waiting time");

	private final int code;

	private final String msg;

	ErrorCode(int code,String msg){
		this.code = code;
		this.msg = msg;
	}

}

